package com.ourway.entity.feishu.user;

import lombok.Data;

import java.io.Serializable;
import java.util.List;

/**
 * 飞书用户
 *
 * @author lwh
 * @date 2021/11/27
 */
@Data
public class FeiShuUserResponseVo implements Serializable {

    private int code;
    private String msg;
    private DataBean data;

    @Data
    public static class DataBean implements Serializable{

        private UserBean user;

        @Data
        public static class UserBean implements Serializable{

            private String union_id;
            private String user_id;
            private String open_id;
            private String name;
            private String en_name;
            private String email;
            private String mobile;
            private boolean mobile_visible;
            private int gender;
            private AvatarBean avatar;
            private StatusBean status;
            private String leader_user_id;
            private String city;
            private String country;
            private String work_station;
            private int join_time;
            private boolean is_tenant_manager;
            private String employee_no;
            private int employee_type;
            private String enterprise_email;
            private String job_title;
            private List<String> department_ids;
            private List<OrdersBean> orders;
            private List<CustomAttrsBean> custom_attrs;


            @Data
            public static class AvatarBean implements Serializable{


                private String avatar_72;
                private String avatar_240;
                private String avatar_640;
                private String avatar_origin;


            }

            @Data
            public static class StatusBean implements Serializable{
                private boolean is_frozen;
                private boolean is_resigned;
                private boolean is_activated;
            }

            @Data
            public static class OrdersBean implements Serializable{
                private String department_id;
                private int user_order;
                private int department_order;
            }

            @Data
            public static class CustomAttrsBean implements Serializable{
                private String type;
                private String id;
                private ValueBean value;

                @Data
                public static class ValueBean implements Serializable{

                    private String text;
                    private String url;
                    private String pc_url;
                    private String option_value;
                    private String name;
                    private String picture_url;
                    private GenericUserBean generic_user;

                    @Data
                    public static class GenericUserBean implements Serializable{

                        private String id;
                        private int type;
                    }
                }
            }
        }
    }
}
